class Counter2 {
    private var value = 0
    private var name = ""
    private var step = 1
    
    println("the main constructor")
    
    def this(name: String) = {
        this()
        this.name = name
        printf("the first aux constructor,name: %s \n",name)
    }
    
    def this(name: String,step: Int) = {
        this(name)
        this.step = step
        printf("the second aux constructor,name: %s,step: %d \n",name,step)
    }
    
    def increment(step: Int): Unit = { value += step }
    def current(): Int = { value }
}
